package com.xj9gg;


import java.util.Properties;

import javax.sql.DataSource;

import org.hibernate.SessionFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

import org.springframework.boot.web.servlet.ServletRegistrationBean;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Import;
import org.springframework.context.annotation.ImportResource;
import org.springframework.transaction.PlatformTransactionManager;


import com.bstek.ureport.console.UReportServlet;


@SpringBootApplication
@EnableCaching
@ImportResource({"classpath:ureport-console-context.xml"})

public class Application {
	
	private DataSource dataSource;
	
	public static void main(String[] args) {
		SpringApplication.run(Application.class, args);
	}
	
	@Bean
    public ServletRegistrationBean UReportServletRegistration() { 
        ServletRegistrationBean registration = new ServletRegistrationBean(new UReportServlet());  
        registration.addUrlMappings("/ureport/*");
        return registration;
    }
	


	


}
